#include<bits/stdc++.h>
#define int long long
using namespace std;
vector<int>s[100005];
signed main(){
    freopen("nim.in","r",stdin);
    freopen("nim.out","w",stdout);
    ios::sync_with_stdio(0);
    cin.tie(0),cout.tie(0);
    int n,x,a,b;
    cin>>n>>x>>a>>b;
    if(a<=b) return cout<<1,0;
    return 0;
}